xen.git
14 years agohvmloader: Formatting cleanups.
Keir Fraser [Mon, 25 Jul 2011 13:09:41 +0000 (14:09 +0100)]
hvmloader: Formatting cleanups.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agohvmloader: Replace bios_relocate hook with bios_load hook
Keir Fraser [Mon, 25 Jul 2011 12:57:49 +0000 (13:57 +0100)]
hvmloader: Replace bios_relocate hook with bios_load hook

Used by OVMF BIOS handler.

Signed-off-by: Bei Guan <gbtju85@gmail.com>
Signed-off-by: Keir Fraser <keir@xen.org>
14 years agofix regression from c/s 23735:537918f518ee
Jan Beulich [Mon, 25 Jul 2011 12:48:08 +0000 (13:48 +0100)]
fix regression from c/s 23735:537918f518ee

This was checking presence of the wrong (old) ELF note. I don't really
understand how this failed consistently only for one of the xen-boot
tests...

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agohvmloader: Declare get_hvm_info_table/get_shared_info as const funcs.
Keir Fraser [Sat, 23 Jul 2011 08:57:04 +0000 (09:57 +0100)]
hvmloader: Declare get_hvm_info_table/get_shared_info as const funcs.

The compiler can perform CSE on their call sites.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agohvmloader: Remove bogus and unused RESERVED_MEMSIZE decl.
Keir Fraser [Sat, 23 Jul 2011 08:56:13 +0000 (09:56 +0100)]
hvmloader: Remove bogus and unused RESERVED_MEMSIZE decl.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agohvmloader: New functions mem_hole_alloc() and mem_hole_populate_ram().
Keir Fraser [Sat, 23 Jul 2011 08:43:47 +0000 (09:43 +0100)]
hvmloader: New functions mem_hole_alloc() and mem_hole_populate_ram().

These can be used by BIOS-specific handlers to set up memory regions
as required by their firmware payload.

Use mem_hole_alloc() to allocate properly reserved space for the
shared-info-page mapping. The old location conflicts with space
required for the OVMF BIOS (support for which is work in progress).

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agoxend: remove PCI device listing from NetBSD, since it's Linux
Roger Pau Monne [Sat, 23 Jul 2011 07:58:37 +0000 (08:58 +0100)]
xend: remove PCI device listing from NetBSD, since it's Linux
specific code.

Signed-off-by: Roger Pau Monne <roger.pau@entel.upc.edu>
14 years agox86, mce: Dump mce log by ERST when mc panic
Liu, Jinsong [Sat, 23 Jul 2011 07:56:58 +0000 (08:56 +0100)]
x86, mce: Dump mce log by ERST when mc panic

We have implemented basic ERST logic before. Now linux3.0 as dom0 has
included APEI logic. Hence it's time to add mce apei interface and
enable APEI ERST feature.
With it, it can save mce log by ERST method when mc panic.

Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
14 years agoacpi: Add support for old and new bios erst, enable mce_apei logic
Liu, Jinsong [Sat, 23 Jul 2011 07:55:59 +0000 (08:55 +0100)]
acpi: Add support for old and new bios erst, enable mce_apei logic

When testing, we found different bios has different understanding
about APEI ERST table header, depending on whether it count ACPI
standard header or not.
This patch add support for both bios version, and enable mce_apei.

Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
14 years agoadd privileged (dom0) kernel feature indication
Jan Beulich [Sat, 23 Jul 2011 07:49:15 +0000 (08:49 +0100)]
add privileged (dom0) kernel feature indication

With our switching away from supporting 32-bit Dom0 operation, users
complained that attempts (perhaps due to lack of knowledge of that
change) to boot the no longer privileged kernel in Dom0 resulted in
apparently silent failure. To make the mismatch explicit and visible,
add dom0 feature flag that the kernel can set to indicate operation as
dom0 is supported.

Due to the way elf_xen_parse_features() worked up to now (getting
fixed here), adding features indications to the old, string based ELF
note would make the respective kernel unusable on older hypervisors.
For that reason, a new ELF Note is being introduced that allows
specifying supported features as a bit array instead (with features
unknown to the hypervisor simply ignored, as now also done by
elf_xen_parse_features(), whereas here unknown kernel-required
features still keep the kernel [and hence VM] from booting).

Introduce and use elf_note_numeric_array() to be forward
compatible (or else an old hypervisor wouldn't be able to parse kernel
specified features occupying more than 64 bits - thanks, Ian!).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agobuild: remove $(DESTDIR) from buildmakevars2file paths
Ian Campbell [Fri, 22 Jul 2011 07:55:19 +0000 (08:55 +0100)]
build: remove $(DESTDIR) from buildmakevars2file paths

23721:0ccb94d533d6 added this by mistake.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
14 years agoAMD IOMMU: remove global interrupt remapping table
Wei Wang [Thu, 21 Jul 2011 13:37:47 +0000 (14:37 +0100)]
AMD IOMMU: remove global interrupt remapping table

...use per-device table instead.

This should work with per-cpu IDTs.  We are safe to remove global
table since SATA device id issue doee not appear in recent
production BIOS.

Signed-off-by: Wei Wang <wei.wang2@amd.com>
14 years agoxen: Fix sedf scheduler
George Dunlap [Thu, 21 Jul 2011 13:35:31 +0000 (14:35 +0100)]
xen: Fix sedf scheduler

Update the sedf scheduler to be compatible with the most recent
generic scheduler interface changes.

Signed-off-by: George Dunlap <george.dunlap@eu.citrix.com>
14 years agox86: add change missing in c/s 23726:fd97ca086df6
Jan Beulich [Thu, 21 Jul 2011 13:34:51 +0000 (14:34 +0100)]
x86: add change missing in c/s 23726:fd97ca086df6

The early "do we need to do anything" check needs adjustment, too.
Thanks to Haitao Shan for pointing this out.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agohvmloader: Switch to absolute addressing for calling hypercall stubs.
Keir Fraser [Wed, 20 Jul 2011 14:02:16 +0000 (15:02 +0100)]
hvmloader: Switch to absolute addressing for calling hypercall stubs.

This is clearer and less fragile than trying to make relative calls
work. In particular, the old approach failed if _start was not
== HVMLOADER_PHYSICAL_ADDRESS. This was the case for some modern
toolchains which reorder functions.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agohvmloader: Remove hard tabs from source files.
Keir Fraser [Wed, 20 Jul 2011 13:52:16 +0000 (14:52 +0100)]
hvmloader: Remove hard tabs from source files.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agolibxl: clean up trailing whitespaces in code.
Wei Liu [Tue, 19 Jul 2011 15:02:36 +0000 (16:02 +0100)]
libxl: clean up trailing whitespaces in code.

Commit exactly the results of running
   find \! -iname '*.txt' -type f -print0 | xargs -0 perl -p -i.bak -E 's/\s+\n/\n/'

Signed-off-by: Wei Liu <liuw@liuw.name>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed: Ian Jackson <ian.jackson@eu.citrix.com>

14 years agolibxl: enabling upstream qemu as pure pv backend.
Wei Liu [Tue, 19 Jul 2011 14:47:14 +0000 (15:47 +0100)]
libxl: enabling upstream qemu as pure pv backend.

This patch makes device_model_{version,override} work for pure pv
guest, so that users can specify upstream qemu as pure pv backend
other than traditional qemu-xen.

This patch also adds device_model_args_{pv,hvm} options for pv and
hvm guest respectively.

Internally, original libxl__create_xenpv_qemu allocates a new empty
dm_info (struct libxl_device_model_info) for every xenpv qemu created.
Now the caller of libxl__create_xenpv_qemu is responsible for
allocating this dm_info.

Signed-off-by: Wei Liu <liuw@liuw.name>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agox86: update Intel CPUID masking code to latest spec
Jan Beulich [Tue, 19 Jul 2011 13:14:51 +0000 (14:14 +0100)]
x86: update Intel CPUID masking code to latest spec

..., which adds masking of the xsave feature leaf.

Also add back (and fix to actually make it do what it was supposed to
do from the beginning) the printing of what specific masking couldn't
be done in case the user requested something the hardware doesn't
support.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agoPCI: consolidate interface for adding devices
Jan Beulich [Tue, 19 Jul 2011 13:14:08 +0000 (14:14 +0100)]
PCI: consolidate interface for adding devices

The functionality of pci_add_device_ext() can be easily folded into
pci_add_device(), and eliminates the need to change two functions for
future adjustments.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86: Remove timeouts from INIT-SIPI-SIPI sequence when using x2apic.
Tim Deegan [Tue, 19 Jul 2011 13:13:01 +0000 (14:13 +0100)]
x86: Remove timeouts from INIT-SIPI-SIPI sequence when using x2apic.

Some of the timeouts are pointless since they're waiting for the ICR
to ack the IPI delivery and that doesn't happen on x2apic.
The others should be benign (and are suggested in the SDM) but
removing them makes AP bringup much more reliable on some test boxes.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
14 years agox86: consistently serialize CMOS/RTC accesses on rtc_lock
Jan Beulich [Tue, 19 Jul 2011 13:10:53 +0000 (14:10 +0100)]
x86: consistently serialize CMOS/RTC accesses on rtc_lock

Since RTC/CMOS accesses aren't atomic, there are possible races
between code paths setting the index register and subsequently
reading/writing the data register. This is supposed to be dealt with
by acquiring rtc_lock, but two places up to now lacked respective
synchronization: Accesses to the EFI time functions and
smpboot_{setup,restore}_warm_reset_vector().

This in turn requires no longer directly passing through guest writes
to the index register, but instead using a machanism similar to that
for PCI config space method 1 accesses.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86-64/EFI: don't call EfiResetSystem() from machine_halt()
Jan Beulich [Tue, 19 Jul 2011 13:10:15 +0000 (14:10 +0100)]
x86-64/EFI: don't call EfiResetSystem() from machine_halt()

c/s 23615:d19e77844267 was a little too eager in adding calls to EFI
runtime services: machine_halt() doesn't really want to power off the
machine, but that's what EfiResetSystem(EfiResetShutdown, ...) (called
through efi_halt_system()) does.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agobuild: consolidate buildmakevars2file
Jan Beulich [Tue, 19 Jul 2011 13:09:48 +0000 (14:09 +0100)]
build: consolidate buildmakevars2file

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agoAdding back guest MSI eoi support for unmaskable MSI interrupt
Shan Haitao [Tue, 19 Jul 2011 07:24:19 +0000 (08:24 +0100)]
Adding back guest MSI eoi support for unmaskable MSI interrupt

This patch adds back proper guest MSI EOI hook for correctly handling
unmaskable MSI interrupt, which is wrongly removed by changset 23703.

Signed-off-by: Shan Haitao <haitao.shan@intel.com>
14 years agoxentrace: update __trace_var comment
Olaf Hering [Tue, 19 Jul 2011 07:22:19 +0000 (08:22 +0100)]
xentrace: update __trace_var comment

Signed-off-by: Olaf Hering <olaf@aepfle.de>
14 years agolibxl: Keyed unions key off an enum instead of an arbitrary expression
Ian Campbell [Mon, 18 Jul 2011 13:52:30 +0000 (14:52 +0100)]
libxl: Keyed unions key off an enum instead of an arbitrary expression

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: use libxl_domain_type enum with libxl__domain_suspend_common
Ian Campbell [Mon, 18 Jul 2011 13:52:30 +0000 (14:52 +0100)]
libxl: use libxl_domain_type enum with libxl__domain_suspend_common

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: specify HVM vs PV in create_info using libxl_domain_type enum
Ian Campbell [Mon, 18 Jul 2011 13:52:30 +0000 (14:52 +0100)]
libxl: specify HVM vs PV in create_info using libxl_domain_type enum

Since libxl_init_build_info now needs an error return and a ctx (to
log to) switch all libxl_init_*_info to have an int return and a ctx.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: specify HVM vs PV in build_info using libxl_domain_type enum
Ian Campbell [Mon, 18 Jul 2011 13:52:30 +0000 (14:52 +0100)]
libxl: specify HVM vs PV in build_info using libxl_domain_type enum

Also caught one place (in libxl__domain_restore_common) which used
info->u.hvm.pae even if !hvm. (fortunately the value was unused in
xc_domain_restore).

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: replace libxl__domain_is_hvm with libxl__domain_type
Ian Campbell [Mon, 18 Jul 2011 13:52:30 +0000 (14:52 +0100)]
libxl: replace libxl__domain_is_hvm with libxl__domain_type

New function returns a libxl_domain_type enum.

Add LIBXL__DOMAIN_IS_TYPE helper macro.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: Give the HVM domain type the name "HVM"
Ian Campbell [Mon, 18 Jul 2011 13:52:29 +0000 (14:52 +0100)]
libxl: Give the HVM domain type the name "HVM"

This is generally used in the Xen universe, rather than "FV" which is
not used elsewhere.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson.citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agoxend NetBSD init script: fixed problem when restarting xend
Roger Pau Monne [Mon, 18 Jul 2011 13:38:31 +0000 (14:38 +0100)]
xend NetBSD init script: fixed problem when restarting xend

When restarting xend, the rc.d script was unable to find the pid of
the running xend, so no process was restarted.

Signed-off-by: Roger Pau Monne <roger.pau@entel.upc.edu>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agoefi: include irq.h to fix compile error in runtime.c
Olaf Hering [Sat, 16 Jul 2011 08:25:48 +0000 (09:25 +0100)]
efi: include irq.h to fix compile error in runtime.c

runtime.c: In function 'efi_rs_enter':
runtime.c:45:5: error: implicit declaration of function 'irq_enter'
[-Werror=implicit-function-declaration]
runtime.c:45:5: error: nested extern declaration of 'irq_enter'
[-Werror=nested-externs]
runtime.c: In function 'efi_rs_leave':
runtime.c:75:5: error: implicit declaration of function 'irq_exit'
[-Werror=implicit-function-declaration]
runtime.c:75:5: error: nested extern declaration of 'irq_exit'
[-Werror=nested-externs]

Signed-off-by: Olaf Hering <olaf@aepfle.de>
14 years agoxentrace: reduce size of extradata in trace_irq_mask()
Olaf Hering [Sat, 16 Jul 2011 08:24:43 +0000 (09:24 +0100)]
xentrace: reduce size of extradata in trace_irq_mask()

Reduce size of extra_data in to avoid possible crash in trace_var.

(XEN) Assertion 'extra_word <= TRACE_EXTRA_MAX' failed at trace.c:687
(XEN) Xen call trace:
(XEN)    [<ffff82c480128783>] __trace_var+0x4d/0x3b8
(XEN)    [<ffff82c480162172>] trace_irq_mask+0x49/0x4b
(XEN)    [<ffff82c4801631ae>] __assign_irq_vector+0x241/0x374
(XEN)    [<ffff82c48015d813>] set_desc_affinity+0x5d/0xd4
(XEN)    [<ffff82c480160708>] set_msi_affinity+0x44/0x1c1
(XEN)    [<ffff82c480162938>] move_masked_irq+0x9c/0xcd
(XEN)    [<ffff82c4801629a7>] move_native_irq+0x3e/0x53
(XEN)    [<ffff82c48015d969>] ack_msi_irq+0x2c/0x6e
(XEN)    [<ffff82c4801622e3>] do_IRQ+0x16f/0x66d

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: George Dunlap <george.dunlap@eu.citrix.com>
14 years agohvm: remove cast from trace_var call for HVMOP_xentrace
Olaf Hering [Sat, 16 Jul 2011 08:24:03 +0000 (09:24 +0100)]
hvm: remove cast from trace_var call for HVMOP_xentrace

trace_var() takes a void pointer, casting is not needed.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: George Dunlap <george.dunlap@eu.citrix.com>
14 years agonestedsvm: Support TSC Rate MSR
Christoph Egger [Sat, 16 Jul 2011 08:23:22 +0000 (09:23 +0100)]
nestedsvm: Support TSC Rate MSR

Support TSC Rate MSR and enable TSC scaling for
nested virtualization.

With it, guest VMs don't need take #VMEXIT to calculate a translated
TSC value when it is running under TSC emulation mode.

I measured native performance of the rdtsc instruction
in the l2 guest with xen-on-xen and both host and
and l1 guest run under TSC emulation mode.

TSC scaling just needs MSR emulation and correct tsc offset
calculation to be done and thus can be emulated also on older
hardware. In this case rdtsc instruction is intercepted and
handled by the host directly and safes the cost of a full
VMRUN/VMEXIT emulation cycle.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
14 years agolibxc: remove obsolete comment.
Ian Campbell [Sat, 16 Jul 2011 08:18:45 +0000 (09:18 +0100)]
libxc: remove obsolete comment.

Seems to predate Xen 3.0...

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
14 years agox86: fix guest migration after c/s 20892:d311d1efc25e
Jan Beulich [Sat, 16 Jul 2011 08:18:21 +0000 (09:18 +0100)]
x86: fix guest migration after c/s 20892:d311d1efc25e

Guests would not manage to run successfully after being migrated to a
host having sufficiently much more memory than the host they were
originally started on.

Subsequently the plan is to re-enable the changes behavior under the
control of a guest kernel announced feature flag.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
14 years ago[IA64] Fix ia64 build for 22396:c1b7aae86cf5
KUWAMURA Shin'ya [Sat, 16 Jul 2011 08:17:20 +0000 (09:17 +0100)]
[IA64] Fix ia64 build for 22396:c1b7aae86cf5

The header xen/include/xen/wait.h conflicts with
xen/include/asm-ia64/linux/wait.h on ia64.
This patch fixes it.

# xen/include/xen/wait.h introduced by 22396:c1b7aae86cf5.

Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
14 years ago[IA64] fix warning: "in_atomic" redefined
KUWAMURA Shin'ya [Sat, 16 Jul 2011 08:16:48 +0000 (09:16 +0100)]
[IA64] fix warning: "in_atomic" redefined

This patch fixes `warning: "in_atomic" redefined'.
# It is introduced by 22395:deb438d43e79.

Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
14 years agoxen/irq: Make it obvious that desc->status fields comprise a bitfield.
Keir Fraser [Sat, 16 Jul 2011 08:15:56 +0000 (09:15 +0100)]
xen/irq: Make it obvious that desc->status fields comprise a bitfield.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agoRemove MSI IRQ storms prevention logic
Shan Haitao [Sat, 16 Jul 2011 08:12:19 +0000 (09:12 +0100)]
Remove MSI IRQ storms prevention logic

The reason is:
1. The logic has negative impact on 10G NIC performance (assigned to
guest) by lowering the interrupt frequency that Xen can handle.
2. Xen already has IRQ rate limit logic, which can also help to
prevent IRQ storms.

Signed-off-by: Shan Haitao <haitao.shan@intel.com>
14 years agoxen/libxc: Clean up pv_cpuid switch statements.
Keir Fraser [Sat, 16 Jul 2011 08:09:46 +0000 (09:09 +0100)]
xen/libxc: Clean up pv_cpuid switch statements.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agoxen/libxc: set CPUID topology leaf as unsupported for PV guests
David Vrabel [Sat, 16 Jul 2011 08:05:45 +0000 (09:05 +0100)]
xen/libxc: set CPUID topology leaf as unsupported for PV guests

The result of a CPUID Extended Topology Enumeration leaf for PV guests
is invalid as the level in ECX is ignored.  This can cause some guests
to loop endlessly when trying to enumerate the topology.

Since the physical topology isn't useful to PV guests set the topology
leaf as unsupported.

Guests affected include Linux kernels prior 2.6.32 where a workaround
was applied ("xen: mask extended topology info in cpu",
82d6469916c6fcfa345636a49004c9d1753905d1).

Signed-off-by: David Vrabel <david.vrabel@citrix.com>
14 years agotools: xencommons NetBSD init script: Multiple bugfixes and improvements
Roger Pau Monne [Fri, 15 Jul 2011 17:22:03 +0000 (18:22 +0100)]
tools: xencommons NetBSD init script: Multiple bugfixes and improvements

Added a cleanup of the xenstore database, to purge old entries,
prevented the restart of xenstore and set Domain-0 name.  Also
replaced the sleep 5 (wait for xenstore to come up) with the method
used in the linux init script.

Signed-off-by: Roger Pau Monne <roger.pau@entel.upc.edu>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Christoph Egger <Christoph.Egger@amd.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agoxl: log domain suspension.
Ian Campbell [Fri, 15 Jul 2011 17:13:28 +0000 (18:13 +0100)]
xl: log domain suspension.

Other shutdown reasons all end up saying something useful while
suspend does not. With this patch the log looks like:
  Domain 670 is dead
  Domain has suspended.
  Done. Exiting now

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agopygrub: prefer Grub2 to Grub1
Ian Campbell [Fri, 15 Jul 2011 17:12:55 +0000 (18:12 +0100)]
pygrub: prefer Grub2 to Grub1

If a VM image has grub2 installed it is likely the one we need to be using.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agoxenbackendd: fix mistaken treatment of unknown backend (eg console) as VIF/VBD
Roger Pau Monne [Fri, 15 Jul 2011 17:09:49 +0000 (18:09 +0100)]
xenbackendd: fix mistaken treatment of unknown backend (eg console) as VIF/VBD

Fixed a cleanup of a variable used in a loop and added a debug message.

Signed-off-by: Roger Pau Monne <roger.pau@entel.upc.edu>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agolibxl: add LIBXL_MAC_{FMT,FMTLEN,BYTES}
Ian Campbell [Thu, 14 Jul 2011 12:24:19 +0000 (13:24 +0100)]
libxl: add LIBXL_MAC_{FMT,FMTLEN,BYTES}

Modelled after LIBXL_UUID_... (where I also add FMTLEN).

signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: rename testenum->testidl
Ian Campbell [Thu, 14 Jul 2011 12:24:11 +0000 (13:24 +0100)]
libxl: rename testenum->testidl

I plan to add some non-Enumeration tests.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: bring command line handling in genwrap.py into one place.
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: bring command line handling in genwrap.py into one place.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: add helper to generate references to Aggregate type members.
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: add helper to generate references to Aggregate type members.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: remove libxl_C_type_of
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: remove libxl_C_type_of

It's not really adding much...

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: refactor code to massage a type into a function argument
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: refactor code to massage a type into a function argument

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: handle generation of pass-by-reference arguments.
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: handle generation of pass-by-reference arguments.

Up until now everything with a destructor function happened to be
pass-by-reference so the current code worked but this will not be the case for
*_to_string and *_to_json. Put some infrastructure in place and use it.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agolibxl: IDL: s/anonynous/anonymous/
Ian Campbell [Thu, 14 Jul 2011 12:22:36 +0000 (13:22 +0100)]
libxl: IDL: s/anonynous/anonymous/

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agobuild: define "move-if-changed" make macro.
Ian Campbell [Thu, 14 Jul 2011 12:22:35 +0000 (13:22 +0100)]
build: define "move-if-changed" make macro.

Use it to replace various places which (should) use the
if ! cmp -s ...; then mv ....; fi
pattern.

Also add an else clause to cleanup the unchanged temporary file.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson.citrix.com>
14 years agotools/pygrub: fix solaris kernel sniff
tools/pygrub: fix solaris kernel sniff [Thu, 14 Jul 2011 17:09:58 +0000 (18:09 +0100)]
tools/pygrub: fix solaris kernel sniff

Solaris 11 build 163+ removes '/platform/i86xpv/kernel/unix' and only the
64-bit PV kernel file '/platform/i86xpv/kernel/amd64/unix' exists.

This patch fixes the detection.

Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
Signed-off-by: Kurt Hackel <kurt.hackel@oracle.com>
Signed-off-by: Frank Che <frank.che@oracle.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agolibxl: Fix segfault in get_all_assigned_devices
Stefano Stabellini [Thu, 14 Jul 2011 14:49:49 +0000 (15:49 +0100)]
libxl: Fix segfault in get_all_assigned_devices

pcidevs is an array of ndev elements (ndev is the number of pci devices
assigend to a specific domain), but we access pcidevs + *num
where *num is the global number of pci devices assigned so far to all
domains in the system.

Fix the issue removing pcidevs and just realloc'ing *list every time we
want to add a new pci device to the array.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agons16550: Clean up code style
Keir Fraser [Thu, 14 Jul 2011 08:43:37 +0000 (09:43 +0100)]
ns16550: Clean up code style

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agoPlaceholder for V4V hypercall and VIRQ numbers
Ross Philipson [Thu, 14 Jul 2011 08:35:40 +0000 (09:35 +0100)]
Placeholder for V4V hypercall and VIRQ numbers

The V4V Xen functionality is currently in our product trees for
XenClient b= ut is not yet in a state suitable for submission. We hope
to make available= the rest of the V4V functionality in the not too
distant future. Since the= se values are already in use in our
product, we would like to reserve them = in open source to prevent
issues or incompatibilities down the road.

Signed-off-by: Ross Philipson <ross.philipson@citrix.com>
14 years agodocs: correct typo in vbd-interface.txt
Ian Campbell [Thu, 14 Jul 2011 08:33:38 +0000 (09:33 +0100)]
docs: correct typo in vbd-interface.txt

d1 is xvdb not xvda.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
14 years agomerge
Keir Fraser [Thu, 14 Jul 2011 08:33:02 +0000 (09:33 +0100)]
merge

14 years agodoc: Update the com1,com2 section with pci and amt options.
Konrad Rzeszutek Wilk [Thu, 14 Jul 2011 08:31:53 +0000 (09:31 +0100)]
doc: Update the com1,com2 section with pci and amt options.

The "xen: Automatically find serial port on PCI/PCIe and AMT devices."
provides the functionality to probe for the I/O base using the
"pci" and "amt" option. Update the documentation with this fact.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
14 years agoxen: Update pci_uart_config to save the BAR1 contents if com2 is used
Konrad Rzeszutek Wilk [Thu, 14 Jul 2011 08:31:12 +0000 (09:31 +0100)]
xen: Update pci_uart_config to save the BAR1 contents if com2 is used

Jan Beulich pointed out that the pci_uart_config can be called for
com2 and we should probe the second BAR instead of the first one.

This patch will probe the BAR0 if it is com1, and BAR1 if its com2.
It also cleans up some of the whitespace problems and changes the
name of the parameter and function from 'magic' to 'pci'.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
14 years agoxen: Restore the BAR and PCI command after resume.
Konrad Rzeszutek Wilk [Thu, 14 Jul 2011 08:30:25 +0000 (09:30 +0100)]
xen: Restore the BAR and PCI command after resume.

Certain PCI serial cards just don't want to remember
what they are when they come out of resume. Save
the BAR and the PCI command values before we suspend and
write them back in when we resume.

Signed-off-by: Roger Cruz <roger.cruz@virtualcomputer.com>
Signed-off-by: Tom Goetz <tom.goetz@virtualcomputer.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
14 years agoxen: Automatically find serial port on PCI/PCIe and AMT devices.
James Mckenzie [Thu, 14 Jul 2011 08:28:23 +0000 (09:28 +0100)]
xen: Automatically find serial port on PCI/PCIe and AMT devices.

Instead of having to manually look the right I/O port on the PCI
devices or AMT devices, lets probe the card and find that
automatically.

This means that you don't have to have this:
 com1=115200,8n1,0xd800,0

But instead can have
 com1=115200,8n1,magic

Or if you have AMT:
 com1=19200,8n1,amt

Signed-off-by: James Mckenzie <jamesmck@bob.uk.xensource.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Tom Goetz <tom.goetz@virtualcomputer.com>
14 years agox86-64: properly handle alias mappings beyond _end
Jan Beulich [Thu, 14 Jul 2011 08:26:13 +0000 (09:26 +0100)]
x86-64: properly handle alias mappings beyond _end

Changeset 19632:b0966b6f5180 wasn't really complete: The Xen image
mapping doesn't end at _end, but a full 16Mb gets mapped during boot
(and never got unmapped so far), hence all of this space was subject
to alias mappings when it comes to cache attribute changes. Unmap all
full large pages between _end and the 16Mb boundary, and include all
other pages beyond _end when checking for aliases.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agolibxl: do not use tap disk backend other than for raw and vhd
Ian Jackson [Fri, 8 Jul 2011 17:35:24 +0000 (18:35 +0100)]
libxl: do not use tap disk backend other than for raw and vhd

tap does not support qcow/qcow2; update disk_try_backend accordingly.

Break out the "backend not suitable for this format" message so it can
be reused.  Remove now-redundant reporting from
libxl_device_disk_local_attach and replace with abort().

Reported-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agotools: fix shared loop device detection in block hotplug script
Zhigang Wang [Fri, 8 Jul 2011 17:12:26 +0000 (18:12 +0100)]
tools: fix shared loop device detection in block hotplug script

We need to cope with 0 or more '0' prefixed to '$dev':

  # stat -c '%D' "/system.img"
  13
  # losetup -a
  /dev/loop0: [0013]:12062248 (/system.img)

Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agotools: Improved LSB headers in init.d scripts
Fabio Fantoni [Fri, 8 Jul 2011 17:10:48 +0000 (18:10 +0100)]
tools: Improved LSB headers in init.d scripts

xendomains service now working also without xend service

Signed-off-by: Fabio Fantoni <fabio.fantoni@heliman.it>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agox86-64/EFI: discard .comment.* sections
Jan Beulich [Fri, 8 Jul 2011 12:23:05 +0000 (13:23 +0100)]
x86-64/EFI: discard .comment.* sections

The SuSE version of gcc produces a non-standard section named
.comment.SUSE.OPTs, but the PE32+ handling in binutils can't really
deal with any section to be placed at virtual address zero (and not
needing to be loaded). Even if binutils did, at least the UEFI
implementation in EDK 1.06 doesn't look at the section characteristics
at all, and hence would attempt to load such a section, and fail or
corrupt other data.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86-64/physdevop: reduce generated code duplication
Jan Beulich [Fri, 8 Jul 2011 12:21:53 +0000 (13:21 +0100)]
x86-64/physdevop: reduce generated code duplication

At least all the helper functions can be used by both the native and
the compat-mode implementations, requiring their parameters to be
adjusted.

Additionally, rather than having the compat mode wrapper source file
blindly define the native structures to be replaced by the compat mode
ones, replace unnecessary (un-)definitions by layout match checks.

In a second step, do_physdev_op() could be split into a part that
needs
re-compilation for compat mode handling and one that can be used for
native and compat mode.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agoRevert 23664:3e3c0a8be9f9
Keir Fraser [Fri, 8 Jul 2011 12:20:09 +0000 (13:20 +0100)]
Revert 23664:3e3c0a8be9f9

14 years agox86/mm: fix 32-bit p2m type lookups
Tim Deegan [Fri, 8 Jul 2011 10:44:23 +0000 (11:44 +0100)]
x86/mm: fix 32-bit p2m type lookups

23300:4b0692880dfa moved a check for 0 into p2m_flags_to_type()
and removed it from its caller, but the new check is only
compiled in 64-bit builds.

Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
14 years agons16550: Implement suspend handler.
Konrad Rzeszutek Wilk [Fri, 8 Jul 2011 07:42:30 +0000 (08:42 +0100)]
ns16550: Implement suspend handler.

For PCI type cards, you need to disable the timer code during
suspend. Otherwise during resume, the timer can be put on the
heap as its being resumed and corrupt it resulting in a crash.

Signed-off-by: Roger Cruz <roger.cruz@virtualcomputer.com>
Signed-off-by: Tom Goetz <tom.goetz@virtualcomputer.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
14 years ago[IA64] kexec: fix ia64 build
KUWAMURA Shin'ya [Fri, 8 Jul 2011 07:39:26 +0000 (08:39 +0100)]
[IA64] kexec: fix ia64 build

23408:1fc3347850c7 causes the following error:
  machine_kexec.c:106: error: static declaration of
  'machine_kexec_get_xen' follows non-static declaration
  /xen-unstable.hg/xen/include/xen/kexec.h:39: error: previous
  declaration of 'machine_kexec_get_xen' was here

Signed-off-by: KUWAMURA Shin'ya <kuwa@jp.fujitsu.com>
14 years agoKEXEC: disconnect all PCI devices from the PCI bus on crash
Andrew Cooper [Fri, 8 Jul 2011 07:38:35 +0000 (08:38 +0100)]
KEXEC: disconnect all PCI devices from the PCI bus on crash

In the case of a crash, IOMMU DMA remapping gets turned off so that
the kdump kernel may boot.  However, this is warned as being dangerous
in the VTD specification if a DMA transaction is in progress.

Also, in the case of a crash, DMA transactions and interrupts from
peripheral devices such as network cards are likely to keep coming in.
Without DMA remapping enabled, the transactions will be writing over
low memory, corrupting the crash state, and perhaps even the kdump
reserved memory.

Therefore, on the crash path, we can disconnect all PCI devices from
their respective buses so that they are no longer able to be DMA
busmasters.  This reduces the risk of DMA transactions corrupting
state (and will also reduce spurious interrupts arriving to the kdump
kernel) until the kdump kernel and properly reset the PCI devices.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
14 years agolibelf: "required" features should also be reported as "supported"
Jan Beulich [Fri, 8 Jul 2011 07:35:00 +0000 (08:35 +0100)]
libelf: "required" features should also be reported as "supported"

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agoadd privileged/unprivileged kernel feature indication
Jan Beulich [Fri, 8 Jul 2011 07:34:29 +0000 (08:34 +0100)]
add privileged/unprivileged kernel feature indication

With our switching away from supporting 32-bit Dom0 operation, users
complained that attempts (perhaps due to lack of knowledge of that
change) to boot the no longer privileged kernel in Dom0 resulted in
apparently silent failure. To make the mismatch explicit and visible,
add feature flags that the kernel can set to indicate operation in
what modes it supports. For backward compatibility, absence of both
feature flags is taken to indicate a kernel that may be capable of
operating in both modes.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agoxenpm: clean up print messages
Kevin Tian [Fri, 8 Jul 2011 07:33:01 +0000 (08:33 +0100)]
xenpm: clean up print messages

Signed-off-by Kevin Tian <kevin.tian@intel.com>

14 years agocpuidle: initialize default Cstate information
Kevin Tian [Fri, 8 Jul 2011 07:32:37 +0000 (08:32 +0100)]
cpuidle: initialize default Cstate information

C0/C1 should be always available when cpuidle is enabled in Xen.
When there's case that Dom0 doesn't register ACPI Cstate information,
e.g. due to BIOS issue or acpi processor module  is not installed,
this patch provides basic C0/C1 information available to xenpm tool.

Signed-off-by: Kevin Tian <kevin.tian@intel.com>
14 years agox86/hvm: Don't expose CPUID time leaf when not using PVRDTSCP
Paul Durrant [Fri, 8 Jul 2011 07:31:10 +0000 (08:31 +0100)]
x86/hvm: Don't expose CPUID time leaf when not using PVRDTSCP

Some versions of Oracle's Solaris PV drivers make a check that the
maximal Xen hypervisor CPUID leaf is <= base leaf + 2 and refuse to
work if this is not the case.  The addition of the time leaf makes the
maximal leaf == base leaf + 3 so this patch introduces a workaround
that obscures the time leaf unless PVRDTSCP is in operation.

Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
14 years agonestedsvm: allow l1 guest to use OSXSAVE
Christoph Egger [Fri, 8 Jul 2011 07:30:56 +0000 (08:30 +0100)]
nestedsvm: allow l1 guest to use OSXSAVE

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
14 years agox86 cpu: Fix bug: unify cpu_dev attr as __cpuinitdata
Liu, Jinsong [Fri, 8 Jul 2011 07:30:41 +0000 (08:30 +0100)]
x86 cpu: Fix bug: unify cpu_dev attr as __cpuinitdata

Currently different x86 cpu define different attr for cpu_dev.
Some cpu define as __initdata, this would be risk under cpu hotplug.
This patch fix the bug, unify them as __cpuinitdata, as what AMD cpu
define now.

Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
               Shan, Haitao <haitao.shan@intel.com>

14 years agolibxl: fix incorrect return of ERROR_INVAL from disk_try_backend
Ian Jackson [Thu, 7 Jul 2011 11:35:05 +0000 (12:35 +0100)]
libxl: fix incorrect return of ERROR_INVAL from disk_try_backend

disk_try_backend is supposed to return 0 or the disk backend format.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agolibxl: sane disk backend selection and validation
Ian Jackson [Wed, 6 Jul 2011 17:26:49 +0000 (18:26 +0100)]
libxl: sane disk backend selection and validation

Introduce a new function libxl__device_disk_set_backend which
does some sanity checks and determines which backend ought to be used.

If the caller specifies LIBXL_DISK_BACKEND_UNKNOWN (which has the
value 0), it tries PHY, TAP and QDISK in that order.  Otherwise it
tries only the specified value.

libxl__device_disk_set_backend (and its helper function
disk_try_backend) inherit the role (and small amounts of the code)
from validate_virtual_disk.  This is called during do_domain_create
and also from libxl_disk_device_add (for the benefit of hotplug
devices).

It also now takes over the role of the scattered fragments of backend
selection found in libxl_device_disk_add,
libxl_device_disk_local_attach and libxl__need_xenpv_qemu.  These
latter functions now simply do the job for the backend they find has
already been specified and checked.

The restrictions on the capabilities of each backend, as expressed in
disk_try_backend (and to an extent in libxl_device_disk_local_attach)
are intended to be identical to the previous arrangements.

In 23618:3173b68c8a94 combined with 23622:160f7f39841b,
23623:c7180c353eb2, "xl" effectively became much more likely to select
TAP as the backend.  With this change to libxl the default backend
selected by the libxl__device_disk_set_backend is intended to once
again to be PHY where possible.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
Cc: Ian Campbell <Ian.Campbell@citrix.com>
14 years agolibxl: testenum.c depends on libxl.h
Olaf Hering [Wed, 6 Jul 2011 15:32:16 +0000 (16:32 +0100)]
libxl: testenum.c depends on libxl.h

testenum.c may fail to compile if libxl.h dependencies are not yet met.

In file included from testenum.c:3:
libxl.h:199:26: error: _libxl_types.h: No such file or directory
In file included from testenum.c:3:
libxl.h:203: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
....

Signed-off-by: Olaf Hering <olaf@aepfle.de>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
14 years agox86: Couple of small cleanups after cpuid faulting patch.
Keir Fraser [Mon, 4 Jul 2011 06:57:32 +0000 (07:57 +0100)]
x86: Couple of small cleanups after cpuid faulting patch.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agox86: Remove redundant cpuid-faulting-related BUG_ON I added.
Keir Fraser [Sat, 2 Jul 2011 08:08:27 +0000 (09:08 +0100)]
x86: Remove redundant cpuid-faulting-related BUG_ON I added.

Signed-off-by: Keir Fraser <keir@xen.org>
14 years agox86: cpuid faulting feature enable
Liu, Jinsong [Fri, 1 Jul 2011 21:28:53 +0000 (22:28 +0100)]
x86: cpuid faulting feature enable

Latest Intel processor add cpuid faulting feature. This patch is used
to support cpuid faulting in Xen.  Like cpuid spoofing, cpuid faulting
mainly used to support live migration. When cpuid faulting enabled,
cpuid instruction runs at cpl>0 will produce GP, vmm then emulate
execution of the cpuid instruction. Hence will appear to guest
software the value chosen by the vmm.

Signed-off-by: Liu, Jinsong <jinsong.liu@intel.com>
Signed-off-by: Keir Fraser <keir@xen.org>
14 years agonestedsvm: fix handling of invalid virtual vmcb
Christoph Egger [Fri, 1 Jul 2011 19:48:00 +0000 (20:48 +0100)]
nestedsvm: fix handling of invalid virtual vmcb

When the l1 guest sets up an invalid vmcb then inject VMEXIT(#INVALID)
rather having the host sitting in an endless loop of injecting #UD.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
14 years agox86: remove the domain parameter from the guest EOI functions.
Jan Beulich [Fri, 1 Jul 2011 19:46:54 +0000 (20:46 +0100)]
x86: remove the domain parameter from the guest EOI functions.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86: make domain_spin_lock_irq_desc() a wrapper of pirq_spin_lock_irq_desc()
Jan Beulich [Fri, 1 Jul 2011 19:45:21 +0000 (20:45 +0100)]
x86: make domain_spin_lock_irq_desc() a wrapper of pirq_spin_lock_irq_desc()

...and drop the now unused struct domain * parameter of the latter.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86: remove unnecessary ALIGN directives
Jan Beulich [Fri, 1 Jul 2011 19:44:50 +0000 (20:44 +0100)]
x86: remove unnecessary ALIGN directives

ENTRY() already includes an ALIGN.

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86-64/mmcfg: fix pci_mmcfg_arch_free()
Jan Beulich [Fri, 1 Jul 2011 19:44:21 +0000 (20:44 +0100)]
x86-64/mmcfg: fix pci_mmcfg_arch_free()

While only used on error paths so far, it should still actually do
something (which iounmap(), being an empty stub, doesn't).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86: streamline page fault path
Jan Beulich [Fri, 1 Jul 2011 19:43:55 +0000 (20:43 +0100)]
x86: streamline page fault path

#PF is, in all "normal" usage models, the only potentially high
frequency (and hence performance sensitive) exception. Thus make it
the fall-through case into handle_exception (rather than
divide_error for x86-32 and not having one at all for x86-64).

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86: adjust pirq_spin_lock_irq_desc()
Jan Beulich [Fri, 1 Jul 2011 19:43:02 +0000 (20:43 +0100)]
x86: adjust pirq_spin_lock_irq_desc()

Remove unnecessary/bogus assertions and add retry loop matching
domain_spin_lock_irq_desc().

Signed-off-by: Jan Beulich <jbeulich@novell.com>
14 years agox86/EFI: adjust installation logic
Jan Beulich [Fri, 1 Jul 2011 19:42:22 +0000 (20:42 +0100)]
x86/EFI: adjust installation logic

We should always install xen.efi into /usr/lib64/efi/; installation
into /boot/efi/efi/$(EFI_VENDOR) remains dependent upon specifying
EFI_VENDOR.

Signed-off-by: Jan Beulich <jbeulich@novell.com>